#!/usr/bin/env php
<?php
require_once 'GoogleFontsFetch.php';

// googlefonts fetch
$fetch = new GoogleFontsFetch();

// 把要下载的google fronts的url地址放到这里, 然后执行  php fetch
$gfarr = array(
	// "https://fonts.googleapis.com/css?family=Poppins:300,300i,400,400i,500,500i,600,600i,700,700i,800,800i,900,900i",
	// "https://fonts.googleapis.com/css?family=Open+Sans:400,400i,600,600i,700,700i&display=swap&subset=cyrillic-ext",
	// "https://fonts.googleapis.com/css2?family=Barlow:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,300;1,400;1,500;1,600;1,700;1,800&display=swap",
	// 'https://fonts.googleapis.com/css2?family=Josefin+Sans:wght@300;400;500;600;700&display=swap',
	// 'https://fonts.googleapis.com/css?family=Rubik:300,300i,400,400i,500,500i,700,700i,900,900i&display=swap&subset=cyrillic',
	// 'https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,300;1,400;1,500;1,600;1,700;1,800&display=swap',
	// 'https://fonts.googleapis.com/css2?family=Barlow:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap',
	// 'https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700;800;900&display=swap',
	// 'https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,300;1,400;1,500;1,600;1,700;1,800&display=swap',
	// 'https://fonts.googleapis.com/css?family=Muli:400,600,700&display=swap',
	// 'https://fonts.googleapis.com/css?family=Poppins:100,300,500,600,700,900&amp;display=swap',
	// 'https://fonts.googleapis.com/css?family=Open+Sans',
	// 'https://fonts.googleapis.com/css?family=Fira+Sans:300,400,500,600,700,900&display=swap',
	// 'https://fonts.googleapis.com/css2?family=Barlow:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,300;1,400;1,500;1,600;1,700;1,800&display=swap',
	// 'https://fonts.googleapis.com/css2?family=Prata&display=swap',
	// 'https://fonts.googleapis.com/css2?family=Arimo:wght@400;700&family=Roboto:ital,wght@0,400;0,500;0,700;0,900;1,400&display=swap',
	// 'https://fonts.googleapis.com/css?family=Roboto+Mono|Source+Sans+Pro:300,400,600',
	// 'https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap',
	// 'http://fonts.googleapis.com/css?family=Varela+Round',
	// 'https://fonts.googleapis.com/css2?family=Lato:wght@300;400;700;900&amp;family=Poppins:wght@200;300;400;500;600;700;800;900&amp;display=swap'
	// 'https://fonts.googleapis.com/css?family=Open+Sans:300,300i,400,400i,600,600i,700,700i,800,800i',
	// 'https://fonts.googleapis.com/css?family=Alegreya+Sans:100,100i,300,300i,400,400i,500,500i,700,700i,800,800i,900,900i',
	// 'https://fonts.googleapis.com/css?family=Montserrat:100,100i,200,200i,300,300i,400,400i,500,500i,600,600i,700,700i,800,800i,900,900i|Niconne',
	// 'https://fonts.googleapis.com/css?family=EB+Garamond:400,400i,500,500i,600,600i,700,700i,800,800i',
	// 'https://fonts.googleapis.com/css?family=Great+Vibes|Poppins:200,300,400,500,600,700,800,900',
	// 'https://fonts.googleapis.com/css?family=Alegreya+Sans:100,100i,300,300i,400,400i,500,500i,700,700i,800,800i,900,900i',
	// 'https://fonts.googleapis.com/css2?family=Cookie&family=Oswald:wght@200;300;400;500;600;700&family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap',
	// 'http://fonts.googleapis.com/css?family=Give+You+Glory&v2',
	// 'http://fonts.googleapis.com/css?family=Wallpoet&v2',
	// 'http://fonts.googleapis.com/css?family=Love+Ya+Like+A+Sister&v2',
	// 'http://fonts.googleapis.com/css?family=Roboto:400,300,500,700',
	// 'https://fonts.googleapis.com/css?family=Open+Sans|Montserrat|Poppins|Josefin+Sans|Roboto+Condensed&display=swap',
	// 'https://fonts.googleapis.com/css?family=Forum',
	// 'https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@400;600;700&display=swap',
	// 'htts://fonts.googleapis.com/css2?family=Ubuntu&display=swap',
	// 'https://fonts.googleapis.com/css2?family=Roboto:wght@100&display=swap',
	// 'https://fonts.googleapis.com/css?family=Catamaran|Mitr|Open+Sans|Montserrat|Poppins|Rubik|Roboto+Condensed|Ubuntu&display=swap',
	// 'https://fonts.googleapis.com/css?family=Open+Sans|Montserrat|Poppins|Josefin+Sans|Roboto+Condensed&display=swap',
	// 'https://fonts.googleapis.com/css?family=Oswald|Barlow+Condensed|Noto+Sans|Montserrat&display=swap',
	'https://fonts.googleapis.com/css2?family=Roboto+Slab:wght@700&family=Roboto:ital,wght@0,400;0,500;0,700;1,400;1,700&display=swap'
);


if (count($gfarr) == 1) {
	$zipfile = $fetch->fetchFont($gfarr[0]);
} else {
	$zipfile = $fetch->fetchFontMulti($gfarr);
}

exit($zipfile);
